# ferreus_orbit Plugins for Dell PowerEdge R410

fo_get_sorted_name(){
  if [ -n "$ID_BUS" ] && [ "$ID_BUS" = "scsi" ]; then
    local card=$(echo $DEVPATH | cut -d/ -f5)
    local target=$(echo $DEVPATH | cut -d/ -f8)
    case "$card" in
      "ata1")
        local id=$(echo "${target}" | cut -d: -f2)
        ;;
      "ata*") 
        local id=S(($(echo "${target}" | cut -d: -f1)+1))
        ;;
      *)
        logger -t "udev" "Device $DEVPATH detected but not supported."; exit 1
        ::
    esac
    if [ -z "$MAXILIUM_ARG_to_fo_name" ]; then
      echo disk=sd$(fo_get_dev_letter ${id})
      exit 0
    else
      local box=$(echo "$target" | cut -d: -f1)
      local disk=$(echo "$target" | cut -d: -f2)
      echo "Box${box}-Disk${disk}"
      exit 0
    fi
  else
    logger -t "udev" "Device $DEVPATH detected but not supported"
    exit 1
  fi
}

get_dispo(){
  echo "Disposition unavailable"
}
